return window->impl_window != window;
}
+static gboolean
+gdk_window_has_alpha (GdkWindow *window)
+{
+ return !gdk_window_has_impl (window) &&
+ window->has_alpha_background;
+}
+
static void
remove_layered_child_area (GdkWindow *window,
cairo_region_t *region)
continue;
/* Only non-impl children with alpha add to the layered region */
- if (!child->has_alpha_background && gdk_window_has_impl (child))
+ if (!gdk_window_has_alpha (child))
continue;
r.x = child->x;
}
}
- if (child->has_alpha_background)
+ if (gdk_window_has_alpha (child))
{
if (layered_region != NULL)
cairo_region_union (layered_region, child_region);
by being drawn in back to front order. However, if implicit paints are not used, for
instance if it was flushed due to a non-double-buffered paint in the middle of the
expose we need to copy in the existing data here. */
- if (!gdk_window_has_impl (window) &&
- window->has_alpha_background &&
+ if (gdk_window_has_alpha (window) &&
(!implicit_paint ||
(implicit_paint && implicit_paint->flushed != NULL && !cairo_region_is_empty (implicit_paint->flushed))))
{
* Everything in the old and new regions that is not copied must be
* invalidated (including children) as this is newly exposed
*/
- if (window->has_alpha_background)
+ if (gdk_window_has_alpha (window))
copy_area = cairo_region_create (); /* Copy nothing for alpha windows */
else
copy_area = cairo_region_copy (new_region);
impl_window = gdk_window_get_impl_window (window);
/* Calculate the area that can be gotten by copying the old area */
- if (window->has_alpha_background)
+ if (gdk_window_has_alpha (window))
copy_area = cairo_region_create (); /* Copy nothing for alpha windows */
else
copy_area = cairo_region_copy (window->clip_region);
impl_window = gdk_window_get_impl_window (window);
/* compute source regions */
- if (window->has_alpha_background)
+ if (gdk_window_has_alpha (window))
copy_area = cairo_region_create (); /* Copy nothing for alpha windows */
else
copy_area = cairo_region_copy (region);